package com.lesso.zgs.sunflower.infra.mapper;

import com.baomidou.mybatisplus.mapper.BaseMapper;
import com.baomidou.mybatisplus.plugins.Page;
import com.lesso.zgs.sunflower.model.EmployeeDevice;
import com.lesso.zgs.sunflower.pojo.dto.EmployeeDeviceQueryDTO;
import com.lesso.zgs.sunflower.pojo.vo.EmployeeDeviceVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 员工设备关系 Mapper 接口
 * </p>
 *
 * @author zgs
 * @since 2025-07-03
 */
@Mapper
public interface EmployeeDeviceMapper extends BaseMapper<EmployeeDevice> {

    /**
     * 分页查询员工设备关系（带员工和设备信息）
     */
    List<EmployeeDeviceVO> selectPageList(Page<EmployeeDeviceVO> page, @Param("dto") EmployeeDeviceQueryDTO dto);

    /**
     * 根据员工ID查询设备
     */
    List<EmployeeDeviceVO> selectByEmployeeId(@Param("employeeId") Long employeeId);
} 